package net.vinote.smart.platform.comm;

public class PlatformConst {

	public static final String SUCCESS = "SUCCESS";

	public static final String FAIL = "FAIL";

	public static final String EXCEPTION = "EXCEPTION";

	public static final String CLEAR = "_CLEAR_";

	public static final String YES = "1";

	public static final String NO = "0";

	public static final int Yes = 1;

	public static final int No = 0;

	public static final String DEFAULT_SRE_FILE = "com/zjw/cfg/sre.xml";

	public static final String MYSQL = "mysql";

	public static final String ORACLE = "oracle";

	public static final String MYSQL_DRIVER = "com.mysql.jdbc.Driver";

	public static final String SYSTEM_CFG_DATABASE_NAME = "database.name";

	public static final String SYSTEM_CFG_DATABASE_DRIVER = "database.driver";

	public static final String SYSTEM_CFG_DATABASE_URL = "database.url";

	public static final String SYSTEM_CFG_DATABASE_USERNAME = "database.username";

	public static final String SYSTEM_CFG_DATABASE_PASSWORD = "database.password";

	public static final String SYSTEM_CFG_DATABASE_MINCONNECT = "database.minConnect";

	public static final String SYSTEM_CFG_DATABASE_MAXCONNECT = "database.maxConnect";

	public static final String SYSTEM_CFG_DATABASE_CONNECTTIMEOUT = "database.connectTimeout";

	public static final String SRE_PREFIX_TABLE = "Table.";

	public static final String SRE_PREFIX_DATAOBJECT_CATALOG = "DOC.";

	public static final String SRE_PREFIX_DATAOBJECT_LIBRARY = "DOL.";

	public static final String SRE_PREFIX_DATAOBJECT_EVENT = "DOE.";

	public static final String SRE_PREFIX_CODE_LIBRARY = "CL.";

	public static final String SRE_PREFIX_LAYOUT_CATALOG = "LC.";

	public static final String SRE_PREFIX_PAGE_ITEM = "PI.";

	public static final String SRE_PREFIX_ROLE_INFO = "RI.";

	public static final String SRE_PREFIX_APP_INFO = "AI.";

	public static final String SRE_PREFIX_APP_INFO_ALL = "ALL.APP_INFO";

	public static final String SRE_PREFIX_APP_ITEM = "AIT.";

	public static final String SRE_PREFIX_DATAWINDOW_PAGE = "DP.";

	public static final String SRE_PREFIX_CLASS_OBJECT = "CLASS.";

	/** 平台模块前缀 */
	public static final String PLATFORM_PREFIX_MODULE = "MODULE.";

	public static final int SQL_UNDO = -1;

	/** 未知 */
	public static final int UN_KNOW = -1;

	/**
	 * $分割符
	 */
	public static final String SPLIT_$ = "$";

	/** =号分隔符 */
	public static final String SPLIT_EQ = "=";

	/** 逗号分隔符 */
	public static final String SPLIT_COMMA = ",";

	/** 用于定义数据窗体以Freeform的形式展现 */
	public static final int LIST = 1;

	/** 用于定义数据窗体以Gird的形式展现 */
	public static final int INFO = 2;

	/** Aes秘钥长度 */
	public static final int AES_KEY_LENGTH = 16;

	public static final String CRLF = "\r\n";

	public interface TreeProperty {
		int DEFAULT = 0;

		/** 子节点可选 */
		int SHOW_CHECKBOX = 1;
	}

	public interface TimeConstant {
		/** 一分钟 */
		public long ONE_MINUTE = 60 * 1000;

		public long ONE_HOUR = ONE_MINUTE * 60;

		public long ONE_DAY = ONE_HOUR * 24;

		public long ONE_MONTH = ONE_DAY * 31;
	}

	public interface DateFormat {
		public String DATE = "yyyyMMdd";
	}

	public interface Number {
		public int ONE = 1;

		public int TEN = 10;
	}

	/**
	 * Html标签值显示来源
	 * 
	 * @author 郑俊伟
	 * 
	 */
	public interface HtmlSource {
		public String CODE = "Code";

		public String JAVA = "Java";

		public String JSON_ARRAY = "JsonArray";
	}

	/**
	 * 系统状态枚举
	 * 
	 * @author 郑俊伟
	 * 
	 */
	public enum LoggerStatus {
		/** 未初始化 */
		UNINITIALIZE,
		/** 临时可用 */
		TEMP_ENABLED,
		/** 可用 */
		ENABLED,
		/** 停止中 */
		STOPING,
		/** 已停止 */
		STOPED,
		/** 关闭中 */
		Closing,
		/** 已关闭 */
		Closed;
	}
}
